/* 全局样式重置与基础设置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    line-height: 1.6;
    color: #333;
    background-color: #f9f9f9;
    padding-bottom: 60px;
}

/* 头部样式 */
header {
    background-color: #2c3e50;
    color: white;
    padding: 1rem 2rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

header h1 {
    font-size: 1.8rem;
    font-weight: 600;
}

/* 主内容区样式 */
main {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

h1 {
    color: #2c3e50;
    margin-bottom: 1.5rem;
    font-size: 1.6rem;
    border-bottom: 2px solid #3498db;
    padding-bottom: 0.5rem;
}

/* 促销信息样式 */
.promotion {
    background-color: #e74c3c;
    color: white;
    padding: 0.8rem;
    border-radius: 4px;
    margin-bottom: 1.5rem;
    text-align: center;
    font-weight: 500;
    animation: flash 2s infinite alternate;
}

@keyframes flash {
    from { background-color: #e74c3c; }
    to { background-color: #c0392b; }
}

/* 商品列表样式 */
.product-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.product-list li {
    background: white;
    border-radius: 8px;
    padding: 1.2rem;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-list li:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.product-list span {
    display: block;
    margin-bottom: 0.8rem;
}

.product-list span:first-child {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2c3e50;
}

.product-list span:last-of-type {
    color: #e67e22;
    font-weight: 500;
}

/* 链接样式 */
a {
    color: #3498db;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

a:hover {
    color: #2980b9;
    text-decoration: underline;
}

/* 表单样式 */
form {
    margin-top: 1.5rem;
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
}

input[type="text"] {
    width: 70%;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    margin-right: 0.5rem;
}

button {
    background-color: #3498db;
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.2s ease;
}

button:hover {
    background-color: #2980b9;
}

/* 页脚样式 */
footer {
    background-color: #2c3e50;
    color: white;
    text-align: center;
    padding: 1rem;
    position: fixed;
    bottom: 0;
    width: 100%;
    font-size: 0.9rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .product-list {
        grid-template-columns: 1fr;
    }
    
    input[type="text"] {
        width: 60%;
    }
    
    header h1 {
        font-size: 1.5rem;
    }
}
